package com.medical.admin.hospital.mapper;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.medical.admin.hospital.common.dto.ComboTypeDto;
import com.medical.admin.hospital.entity.ComboType;

public interface ComboTypeMapper extends BaseMapper<ComboType> {
    default ComboType findByComboTypeName(String comboTypeName){
        LambdaQueryWrapper<ComboType> queryWrapper = new LambdaQueryWrapper<>();
        queryWrapper.eq(comboTypeName!=null,ComboType::getComboTypeName,comboTypeName);
        return this.selectOne(queryWrapper);
    };

}